package com.atguigu.edu.realtime.publisher.service.impl;

import com.atguigu.edu.realtime.publisher.bean.SourceTraPer;
import com.atguigu.edu.realtime.publisher.bean.TradeCt;
import com.atguigu.edu.realtime.publisher.mapping.TradeCountMapper;
import com.atguigu.edu.realtime.publisher.service.TradeCountService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TradeCountServiceImpl implements TradeCountService {
    @Autowired
    TradeCountMapper tradeCountMapper;

    @Override
    public List<TradeCt> getSourceOrderCnt(Integer date) {
        return tradeCountMapper.selectSourceOrderCnt(date);
    }

    @Override
    public List<TradeCt> getProvinceOrderCnt(Integer date) {
        return tradeCountMapper.selectProvinceOrderCnt(date);
    }

    @Override
    public List<TradeCt> getOrderCnt(Integer date) {
        return tradeCountMapper.selectOrderCnt(date);
    }

    @Override
    public List<SourceTraPer> getSourceTraPer(Integer date) {
        return tradeCountMapper.selectSourceTraPer(date);
    }
}
